import 'package:flutter/material.dart';

class TravelPage extends StatefulWidget {
  // TravelPage({Key key}) : super(key: key);

  @override
  _TravelPageState createState() => _TravelPageState();
}

class _TravelPageState extends State<TravelPage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        elevation: 0,
        // 透明颜色地图有了之后放开
        // backgroundColor: Colors.transparent,
        title: Text("我的行程"),
      ),
      body: Container(
        child: Stack(
          children: [
            // 覆盖物
            Container(
              margin: EdgeInsets.all(5),
              child: Column(
                children: [
                  // 今日行程
                  Row(
                    mainAxisAlignment: MainAxisAlignment.center,
                    crossAxisAlignment: CrossAxisAlignment.center,
                    children: [
                      Expanded(
                        child: Container(
                          height: 48,
                          decoration: BoxDecoration(
                              color: Colors.red.shade900.withOpacity(0.5),
                              borderRadius:
                                  const BorderRadius.all(Radius.circular(16.0)),
                              boxShadow: <BoxShadow>[
                                BoxShadow(
                                    color: Colors.red.shade100.withOpacity(0.5),
                                    offset: const Offset(1.1, 1.1),
                                    blurRadius: 10.0)
                              ]),
                          child: Center(
                            child: Text(
                              '当前行程',
                              textAlign: TextAlign.left,
                              style: TextStyle(
                                  fontWeight: FontWeight.w600,
                                  fontSize: 18,
                                  letterSpacing: 0.0,
                                  color: Colors.white),
                            ),
                          ),
                        ),
                      ),
                      const SizedBox(
                        width: 16,
                      ),
                      Container(
                        width: 48,
                        height: 48,
                        child: Container(
                          decoration: BoxDecoration(
                              color: Colors.white24,
                              borderRadius:
                                  const BorderRadius.all(Radius.circular(16.0)),
                              boxShadow: <BoxShadow>[
                                BoxShadow(
                                    color: Colors.lightBlue.withOpacity(0.5),
                                    offset: const Offset(1.1, 1.1),
                                    blurRadius: 10.0)
                              ]),
                        ),
                      )
                    ],
                  ),
                  Container(
                    margin: EdgeInsets.fromLTRB(15, 0, 15, 0),
                    child: TextField(
                      decoration: InputDecoration(
                        hintText: "选择点",
                        fillColor: Colors.grey,
                      ),
                    ),
                  ),
                  // 历史行程
                  Container(
                    child: Text('历史行程'),
                  ),
                ],
              ),
            ),
          ],
        ),
      ),
    );
  }
}
